<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

function imd5($str = '')
{
    $str = trim($str);
    $str = md5($str);
    $sub = substr($str, 0, 10);
    $sub .= substr($str, 15, 10);
    return $sub;
}
function encrypt($str)
{
    $str = trim($str);
    $en = new CI_Encrypt();
    return $en->encode($str);
}
function decrypt($str)
{
    $str = trim($str);
    $en = new CI_Encrypt();
    return $en->decode($str);
    
}